import java.text.SimpleDateFormat;
import java.util.Date;
import java.util.TimerTask;

public class ShowTimeThread extends TimerTask{

	private MainFrame frame;
	
	public ShowTimeThread(MainFrame frame){
		this.frame = frame;
	}
	
	@Override
	public void run() {

		SimpleDateFormat sdf = new SimpleDateFormat("yyyy-MM-dd HH:mm:ss");
		frame.lblTime.setText(sdf.format(new Date()));
	}

}
